// 获取轮播图数据封装
import { getBanners } from "@/api/home";
import { ref } from "vue";

export default function useBanners() {
  const banners = ref([]);
  const getData = (distributionSite) => {
    getBanners(distributionSite).then((data) => {
      banners.value = data.result;
    });
  };
  return {
    banners,
    getData,
  };
}
